<%@ page language="java" contentType="text/html; charset=utf-8"
	pageEncoding="utf-8"%>
<%@ page isELIgnored="false" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title></title>
</head>
<body>

<jsp:scriptlet>
    String name = (String) request.getAttribute("name"); 
</jsp:scriptlet>

<%-- 利用 action element 一定要自己在 class attribute 用"完整名稱"，用 Directive element 在
             頁面最前頭做宣告 <%@page import=""%> 這邊一樣會出錯  --%>
<jsp:useBean class="DTO.User" id="user" scope="request" />

the name we got is <b><%=name%></b><br />
the host using EL to get is <b>${pageContext.request.queryString}</b><br />

The User attribute in request scope we get is <br/>
<b>account is <jsp:getProperty name="user" property="account" /></b><br />
<!-- <b>passowrd is ${requestScope.user.password} </b><br />-->
<b>passowrd is ${requestScope['user']['password']} </b><br />
<b>alias is ${user['alias']}</b><br />
<br />

<b>Testing using map to pass values --------------</b><br />
<b>account is ${requestScope.paramMap['account']}</b><br />
<b>password is ${paramMap['user'].password}</b><br />
<b>alias is ${paramMap.user['alias'] }</b><br />
</body>
</html>